<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
	<title>comandos</title>
	<meta http-equiv="content-type" content="text/html;charset=utf-8" />
	<meta name="generator" content="Geany 1.22" />
	<meta name="date" content="2014-02-21T02:27:44-0300" />
	<style type="text/css">
	body
	{
		font-family: Monospace, monospace;
		font-size: 10pt;
	}
	.style_0
	{
		color: #000000;
		background-color: #ffffff;
	}
	.style_1
	{
		color: #000000;
		background-color: #ffffff;
	}
	.style_2
	{
		color: #d00000;
		background-color: #ffffff;
	}
	.style_4
	{
		color: #d00000;
		background-color: #ffffff;
	}
	.style_5
	{
		color: #007f7f;
		background-color: #ffffff;
	}
	.style_7
	{
		color: #007f00;
		background-color: #ffffff;
	}
	.style_8
	{
		color: #007f00;
		background-color: #ffffff;
	}
	.style_9
	{
		color: #00007f;
		background-color: #ffffff;
		font-weight: bold;
	}
	.style_10
	{
		color: #ff8000;
		background-color: #ffffff;
	}
	.style_13
	{
		color: #301010;
		background-color: #ffffff;
	}
	.style_32
	{
		color: #bfe77700;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_34
	{
		color: #000000;
		background-color: #000000;
		font-style: italic;
	}
	.style_35
	{
		color: #b6ec6fdd;
		background-color: #bfe77740;
		font-style: italic;
	}
	.style_37
	{
		color: #000000;
		background-color: #000000;
		font-style: italic;
	}
	.style_39
	{
		color: #b6c3dc09;
		background-color: #b6eee35c;
		font-weight: bold;
	}
	.style_40
	{
		color: #b6eee35c;
		background-color: #bfe7791c;
		font-weight: bold;
	}
	.style_41
	{
		color: #bfe7792c;
		background-color: #9208810;
		font-weight: bold;
		font-style: italic;
	}
	.style_43
	{
		color: #000000;
		background-color: #000000;
	}
	.style_45
	{
		color: #000000;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_46
	{
		color: #920a628;
		background-color: #b6e252d2;
		font-style: italic;
	}
	.style_47
	{
		color: #b6c30440;
		background-color: #bfe78a04;
		font-weight: bold;
		font-style: italic;
	}
	.style_48
	{
		color: #b6e995a0;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_49
	{
		color: #b761d900;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_50
	{
		color: #000008;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_51
	{
		color: #b6e248df;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_52
	{
		color: #93073c8;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_53
	{
		color: #b6e99000;
		background-color: #9208810;
		font-weight: bold;
	}
	.style_54
	{
		color: #b6e99000;
		background-color: #b6dc4226;
		font-weight: bold;
		font-style: italic;
	}
	.style_55
	{
		color: #b6dfdf0e;
		background-color: #b6e995a0;
		font-weight: bold;
	}
	.style_56
	{
		color: #9208810;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_57
	{
		color: #8e9d6c8;
		background-color: #000078;
		font-weight: bold;
		font-style: italic;
	}
	.style_58
	{
		color: #8e9d0c0;
		background-color: #b6ecbecd;
		font-weight: bold;
		font-style: italic;
	}
	.style_59
	{
		color: #b6c3ccdf;
		background-color: #8f30238;
		font-weight: bold;
		font-style: italic;
	}
	.style_60
	{
		color: #93a5a20;
		background-color: #9208810;
		font-weight: bold;
		font-style: italic;
	}
	.style_61
	{
		color: #000145;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_63
	{
		color: #b6eee000;
		background-color: #93a5a20;
		font-weight: bold;
		font-style: italic;
	}
	.style_64
	{
		color: #b6eee35c;
		background-color: #93a5a20;
		font-weight: bold;
		font-style: italic;
	}
	.style_65
	{
		color: #000000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_66
	{
		color: #00014c;
		background-color: #b76fa000;
		font-weight: bold;
		font-style: italic;
	}
	.style_67
	{
		color: #b73f94fb;
		background-color: #93a5a20;
		font-weight: bold;
	}
	.style_68
	{
		color: #93a5a20;
		background-color: #b76fa000;
		font-weight: bold;
		font-style: italic;
	}
	.style_69
	{
		color: #000146;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_71
	{
		color: #b6eee000;
		background-color: #bfe77bd0;
		font-weight: bold;
		font-style: italic;
	}
	.style_72
	{
		color: #93a5a20;
		background-color: #8ed1b20;
		font-style: italic;
	}
	.style_73
	{
		color: #b76fa000;
		background-color: #93a5a20;
		font-weight: bold;
		font-style: italic;
	}
	.style_74
	{
		color: #8ed1b08;
		background-color: #b6eabacd;
		font-weight: bold;
	}
	.style_75
	{
		color: #bfe77bd0;
		background-color: #bfe77b7c;
		font-weight: bold;
		font-style: italic;
	}
	.style_76
	{
		color: #b6eee000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_77
	{
		color: #000000;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_78
	{
		color: #000001;
		background-color: #b6c3ccdf;
		font-weight: bold;
		font-style: italic;
	}
	.style_79
	{
		color: #b6e24a4f;
		background-color: #93a5a20;
		font-weight: bold;
		font-style: italic;
	}
	.style_80
	{
		color: #40000004;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_81
	{
		color: #bfe77b7c;
		background-color: #b6eee35c;
		font-weight: bold;
		font-style: italic;
	}
	.style_82
	{
		color: #b6e99000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_83
	{
		color: #b6ebf18f;
		background-color: #b6eee35c;
		font-style: italic;
	}
	.style_84
	{
		color: #bfe77b7c;
		background-color: #bfe77bd0;
		font-weight: bold;
		font-style: italic;
	}
	.style_85
	{
		color: #000050;
		background-color: #bfe77b74;
		font-weight: bold;
		font-style: italic;
	}
	.style_86
	{
		color: #b6eee35c;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_88
	{
		color: #b6eee000;
		background-color: #bfe77bd0;
		font-weight: bold;
		font-style: italic;
	}
	.style_89
	{
		color: #000001;
		background-color: #bfe77b88;
		font-weight: bold;
		font-style: italic;
	}
	.style_90
	{
		color: #bfe77d88;
		background-color: #b6eb18d2;
		font-weight: bold;
		font-style: italic;
	}
	.style_91
	{
		color: #b6eee000;
		background-color: #bfe77bd0;
		font-weight: bold;
		font-style: italic;
	}
	.style_92
	{
		color: #bfe77bd0;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_94
	{
		color: #bfe77bd0;
		background-color: #b6e24d30;
		font-weight: bold;
		font-style: italic;
	}
	.style_96
	{
		color: #000000;
		background-color: #8ed1b20;
		font-weight: bold;
		font-style: italic;
	}
	.style_97
	{
		color: #000000;
		background-color: #bfe77c10;
		font-weight: bold;
		font-style: italic;
	}
	.style_99
	{
		color: #000000;
		background-color: #b6eee35c;
		font-weight: bold;
		font-style: italic;
	}
	.style_100
	{
		color: #8ed69f8;
		background-color: #bfe77bd0;
		font-weight: bold;
		font-style: italic;
	}
	.style_101
	{
		color: #000069;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_102
	{
		color: #913dad0;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_103
	{
		color: #000004;
		background-color: #8ed69f8;
		font-weight: bold;
		font-style: italic;
	}
	.style_106
	{
		color: #000000;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_108
	{
		color: #000001;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_109
	{
		color: #000050;
		background-color: #b7505ae0;
		font-weight: bold;
		font-style: italic;
	}
	.style_110
	{
		color: #b7505ae0;
		background-color: #b6e24a4f;
		font-weight: bold;
		font-style: italic;
	}
	.style_111
	{
		color: #b6e248df;
		background-color: #93a5a28;
		font-weight: bold;
	}
	.style_112
	{
		color: #93a5a28;
		background-color: #b6dc4046;
		font-weight: bold;
		font-style: italic;
	}
	.style_113
	{
		color: #b6e99000;
		background-color: #93a5a20;
		font-weight: bold;
	}
	.style_114
	{
		color: #b6e99000;
		background-color: #b6dc41ef;
		font-weight: bold;
		font-style: italic;
	}
	.style_115
	{
		color: #b6dfdf0e;
		background-color: #b6e995a0;
		font-weight: bold;
	}
	.style_116
	{
		color: #93a5a20;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_117
	{
		color: #8e9d6c8;
		background-color: #000068;
		font-weight: bold;
		font-style: italic;
	}
	.style_118
	{
		color: #8e9d0b8;
		background-color: #b6ecbecd;
		font-weight: bold;
		font-style: italic;
	}
	.style_119
	{
		color: #b6c3ccdf;
		background-color: #8f2e2c8;
		font-weight: bold;
		font-style: italic;
	}
	.style_120
	{
		color: #913dad0;
		background-color: #93a5a20;
		font-weight: bold;
		font-style: italic;
	}
	.style_121
	{
		color: #000145;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_123
	{
		color: #b6eee000;
		background-color: #913dad0;
		font-weight: bold;
		font-style: italic;
	}
	.style_124
	{
		color: #b6eee35c;
		background-color: #913dad0;
		font-weight: bold;
		font-style: italic;
	}
	.style_125
	{
		color: #000000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_126
	{
		color: #9319990;
		background-color: #b76fa000;
		font-weight: bold;
		font-style: italic;
	}
	.style_127
	{
		color: #b73f94fb;
		background-color: #913dad0;
		font-weight: bold;
	}
	.style_128
	{
		color: #913dad0;
		background-color: #b76fa000;
		font-weight: bold;
		font-style: italic;
	}
	.style_129
	{
		color: #000146;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_131
	{
		color: #b6eee000;
		background-color: #bfe78080;
		font-weight: bold;
		font-style: italic;
	}
	.style_132
	{
		color: #913dad0;
		background-color: #8ed1b20;
		font-style: italic;
	}
	.style_133
	{
		color: #b76fa000;
		background-color: #913dad0;
		font-weight: bold;
		font-style: italic;
	}
	.style_134
	{
		color: #8ed1b08;
		background-color: #b6eabacd;
		font-weight: bold;
	}
	.style_135
	{
		color: #bfe78080;
		background-color: #bfe7802c;
		font-weight: bold;
	}
	.style_136
	{
		color: #b6eee000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_137
	{
		color: #000000;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_138
	{
		color: #000001;
		background-color: #b6c3ccdf;
		font-weight: bold;
		font-style: italic;
	}
	.style_139
	{
		color: #b6e24a4f;
		background-color: #913dad0;
		font-weight: bold;
		font-style: italic;
	}
	.style_140
	{
		color: #40000003;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_141
	{
		color: #bfe7802c;
		background-color: #b6eee35c;
		font-weight: bold;
		font-style: italic;
	}
	.style_142
	{
		color: #000000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_143
	{
		color: #b6ebf18f;
		background-color: #b6eee35c;
		font-style: italic;
	}
	.style_144
	{
		color: #bfe7802c;
		background-color: #bfe78080;
		font-weight: bold;
		font-style: italic;
	}
	.style_145
	{
		color: #000050;
		background-color: #bfe78024;
		font-weight: bold;
		font-style: italic;
	}
	.style_146
	{
		color: #b6eee35c;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_148
	{
		color: #b6eee000;
		background-color: #bfe78080;
		font-weight: bold;
		font-style: italic;
	}
	.style_149
	{
		color: #000001;
		background-color: #bfe78038;
		font-weight: bold;
		font-style: italic;
	}
	.style_150
	{
		color: #bfe78238;
		background-color: #b6eb18d2;
		font-weight: bold;
		font-style: italic;
	}
	.style_151
	{
		color: #b6eee000;
		background-color: #bfe78080;
		font-weight: bold;
		font-style: italic;
	}
	.style_152
	{
		color: #bfe78080;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_154
	{
		color: #bfe78080;
		background-color: #b6e24d30;
		font-weight: bold;
		font-style: italic;
	}
	.style_156
	{
		color: #000000;
		background-color: #8ed1b20;
		font-weight: bold;
		font-style: italic;
	}
	.style_157
	{
		color: #000000;
		background-color: #bfe780c0;
		font-weight: bold;
		font-style: italic;
	}
	.style_159
	{
		color: #000000;
		background-color: #b6eee35c;
		font-weight: bold;
		font-style: italic;
	}
	.style_160
	{
		color: #8ed69f8;
		background-color: #bfe78080;
		font-weight: bold;
	}
	.style_161
	{
		color: #000069;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_162
	{
		color: #92a0c60;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_163
	{
		color: #000004;
		background-color: #8ed69f8;
		font-weight: bold;
		font-style: italic;
	}
	.style_166
	{
		color: #000000;
		background-color: #931dce0;
		font-weight: bold;
		font-style: italic;
	}
	.style_168
	{
		color: #000001;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_170
	{
		color: #000000;
		background-color: #b6e24a4f;
		font-weight: bold;
	}
	.style_171
	{
		color: #b6e248df;
		background-color: #913dad8;
		font-weight: bold;
		font-style: italic;
	}
	.style_172
	{
		color: #913dad8;
		background-color: #b6dc4046;
		font-weight: bold;
		font-style: italic;
	}
	.style_173
	{
		color: #b6e99000;
		background-color: #913dad0;
		font-weight: bold;
	}
	.style_174
	{
		color: #b6e99000;
		background-color: #b6dc41ef;
		font-weight: bold;
		font-style: italic;
	}
	.style_175
	{
		color: #b6dfdf0e;
		background-color: #b6e995a0;
		font-weight: bold;
	}
	.style_176
	{
		color: #913dad0;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_177
	{
		color: #8e9d6c8;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_178
	{
		color: #8e9d0b0;
		background-color: #b6c3ccdf;
		font-weight: bold;
		font-style: italic;
	}
	.style_179
	{
		color: #b6e24a4f;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_180
	{
		color: #000000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_181
	{
		color: #92a0c60;
		background-color: #8ed1b08;
		font-weight: bold;
		font-style: italic;
	}
	.style_182
	{
		color: #b6e99000;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_183
	{
		color: #b6ec55b1;
		background-color: #b6eee35c;
		font-weight: bold;
		font-style: italic;
	}
	.style_184
	{
		color: #8f100d0;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_185
	{
		color: #b6ecfee4;
		background-color: #b7504440;
		font-weight: bold;
		font-style: italic;
	}
	.style_187
	{
		color: #b76fa000;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_188
	{
		color: #92a0c60;
		background-color: #000146;
		font-style: italic;
	}
	.style_189
	{
		color: #b76fa000;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_190
	{
		color: #000000;
		background-color: #b76fa000;
		font-weight: bold;
		font-style: italic;
	}
	.style_191
	{
		color: #b751f591;
		background-color: #92a0c60;
	}
	.style_192
	{
		color: #b751f517;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_193
	{
		color: #8ed1b20;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_194
	{
		color: #92a0c60;
		background-color: #b6eac49e;
		font-weight: bold;
		font-style: italic;
	}
	.style_195
	{
		color: #b6eabacd;
		background-color: #000001;
		font-style: italic;
	}
	.style_196
	{
		color: #bfe784ec;
		background-color: #b751f510;
		font-weight: bold;
		font-style: italic;
	}
	.style_198
	{
		color: #000001;
		background-color: #bfe78540;
		font-weight: bold;
		font-style: italic;
	}
	.style_199
	{
		color: #b6c3ccdf;
		background-color: #bfe78500;
		font-weight: bold;
		font-style: italic;
	}
	.style_200
	{
		color: #92a0c60;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_201
	{
		color: #000000;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_203
	{
		color: #b6eee000;
		background-color: #bfe784ec;
		font-weight: bold;
		font-style: italic;
	}
	.style_204
	{
		color: #b6eee35c;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_205
	{
		color: #bfe78540;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_206
	{
		color: #bfe784e4;
		background-color: #b6dc54fd;
		font-weight: bold;
		font-style: italic;
	}
	.style_207
	{
		color: #b6eee000;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_208
	{
		color: #92a0c68;
		background-color: #000050;
	}
	.style_209
	{
		color: #bfe78540;
		background-color: #8e9f6e0;
		font-weight: bold;
		font-style: italic;
	}
	.style_210
	{
		color: #bfe784f8;
		background-color: #b6eee000;
		font-weight: bold;
		font-style: italic;
	}
	.style_211
	{
		color: #b6eb18d2;
		background-color: #92a0c60;
		font-style: italic;
	}
	.style_212
	{
		color: #bfe78540;
		background-color: #bfe78554;
		font-weight: bold;
		font-style: italic;
	}
	.style_213
	{
		color: #000001;
		background-color: #b6ebe1d9;
		font-weight: bold;
		font-style: italic;
	}
	.style_214
	{
		color: #bfe78540;
		background-color: #b6ec6fdd;
		font-weight: bold;
	}
	.style_215
	{
		color: #b6e24d30;
		background-color: #8ea14c8;
		font-weight: bold;
		font-style: italic;
	}
	.style_220
	{
		color: #b6eee35c;
		background-color: #bfe7872c;
		font-weight: bold;
		font-style: italic;
	}
	.style_221
	{
		color: #bfe78540;
		background-color: #000020;
		font-weight: bold;
		font-style: italic;
	}
	.style_223
	{
		color: #b6e99000;
		background-color: #b6c3f7cf;
		font-weight: bold;
		font-style: italic;
	}
	.style_224
	{
		color: #000000;
		background-color: #bfe78580;
		font-weight: bold;
		font-style: italic;
	}
	.style_225
	{
		color: #b6e252b6;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_226
	{
		color: #ad606e18;
		background-color: #b6e252d2;
		font-style: italic;
	}
	.style_227
	{
		color: #b6e99000;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_229
	{
		color: #000000;
		background-color: #000010;
		font-weight: bold;
		font-style: italic;
	}
	.style_230
	{
		color: #000018;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_231
	{
		color: #b6de75bb;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_232
	{
		color: #ad606e18;
		background-color: #000002;
		font-weight: bold;
		font-style: italic;
	}
	.style_233
	{
		color: #ad606e18;
		background-color: #8e9d098;
		font-weight: bold;
		font-style: italic;
	}
	.style_234
	{
		color: #b6e99000;
		background-color: #b6dc4226;
		font-weight: bold;
		font-style: italic;
	}
	.style_235
	{
		color: #b6e99000;
		background-color: #b6c3f7cf;
		font-weight: bold;
		font-style: italic;
	}
	.style_236
	{
		color: #000000;
		background-color: #92a0d08;
		font-weight: bold;
		font-style: italic;
	}
	.style_237
	{
		color: #b6e252b6;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_238
	{
		color: #b76fa000;
		background-color: #b73f9564;
		font-weight: bold;
		font-style: italic;
	}
	.style_239
	{
		color: #b6eee338;
		background-color: #92a0c68;
		font-weight: bold;
		font-style: italic;
	}
	.style_240
	{
		color: #0000e0;
		background-color: #92a0d08;
		font-weight: bold;
		font-style: italic;
	}
	.style_241
	{
		color: #000145;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_243
	{
		color: #000000;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_244
	{
		color: #92a0c60;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_245
	{
		color: #000035;
		background-color: #000000;
		font-weight: bold;
		font-style: italic;
	}
	.style_246
	{
		color: #92a0c60;
		background-color: #b6eee338;
		font-weight: bold;
	}
	.style_247
	{
		color: #b6eee000;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_248
	{
		color: #92a0c60;
		background-color: #000050;
		font-weight: bold;
		font-style: italic;
	}
	.style_249
	{
		color: #b76fa000;
		background-color: #000001;
		font-weight: bold;
		font-style: italic;
	}
	.style_250
	{
		color: #b7342819;
		background-color: #92a0c60;
		font-weight: bold;
		font-style: italic;
	}
	.style_251
	{
		color: #b6e99000;
		background-color: #939ba88;
		font-weight: bold;
		font-style: italic;
	}
	.style_252
	{
		color: #000000;
		background-color: #939ba88;
		font-weight: bold;
		font-style: italic;
	}
	.style_253
	{
		color: #fffffff8;
		background-color: #b6e99000;
		font-weight: bold;
		font-style: italic;
	}
	.style_254
	{
		color: #000000;
		background-color: #8fa7a28;
		font-weight: bold;
		font-style: italic;
	}
	.style_255
	{
		color: #80991de;
		background-color: #939ba88;
		font-weight: bold;
		font-style: italic;
	}

	</style>
</head>

<body>
<p>
<span class="style_9">UNIT&nbsp;</span><span class="style_1">comandos</span><span class="style_13">;</span><br />
<span class="style_9">INTERFACE</span><br />
<br />
<span class="style_9">Uses&nbsp;</span><span class="style_1">BaseUnix</span><span class="style_13">,&nbsp;</span><span class="style_1">Unix</span><span class="style_13">,&nbsp;</span><span class="style_1">crt</span><span class="style_13">,&nbsp;</span><span class="style_1">utilidades</span><span class="style_13">;</span><br />
<br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">cat&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_9">var&nbsp;</span><span class="style_1">dir1</span><span class="style_13">,</span><span class="style_1">dir2</span><span class="style_13">:&nbsp;</span><span class="style_9">string</span><span class="style_13">;&nbsp;</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;CAT&nbsp;-&nbsp;Concatena&nbsp;hasta&nbsp;dos&nbsp;archivos,&nbsp;o&nbsp;un&nbsp;archivo&nbsp;con&nbsp;la&nbsp;salida&nbsp;estandar</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">exec&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">param1</span><span class="style_13">:&nbsp;</span><span class="style_9">String</span><span class="style_13">;&nbsp;</span><span class="style_1">param2</span><span class="style_13">:&nbsp;</span><span class="style_9">Array&nbsp;of&nbsp;</span><span class="style_1">AnsiString</span><span class="style_13">);&nbsp;&nbsp;</span><span class="style_4">//&nbsp;EXEC&nbsp;-&nbsp;Ejecuta&nbsp;un&nbsp;programa&nbsp;externo.&nbsp;Ruta&nbsp;relativa&nbsp;o&nbsp;absoluta.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">kill&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">signal</span><span class="style_13">,&nbsp;</span><span class="style_1">proc</span><span class="style_13">:&nbsp;</span><span class="style_1">longint</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;KILL&nbsp;-&nbsp;Envía&nbsp;una&nbsp;señal&nbsp;a&nbsp;un&nbsp;proceso.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">ls&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;LS&nbsp;-&nbsp;Lista&nbsp;los&nbsp;archivos&nbsp;de&nbsp;un&nbsp;determinado&nbsp;directorio.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsA&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;variante&nbsp;de&nbsp;LS,&nbsp;lista&nbsp;archivos&nbsp;ocultos.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsF&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;variante&nbsp;de&nbsp;LS,&nbsp;lista&nbsp;sin&nbsp;ordenar&nbsp;ni&nbsp;aplicar&nbsp;colores.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsL&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;variante&nbsp;de&nbsp;LS,&nbsp;lista&nbsp;archivos&nbsp;en&nbsp;formato&nbsp;largo.</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsLA&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;LS&nbsp;-l&nbsp;-a</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsLF&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;LS&nbsp;-l&nbsp;-f</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsAF&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;LF&nbsp;-a&nbsp;-f</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsAFL&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;LF&nbsp;-a&nbsp;-f&nbsp;-l</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">pwd&nbsp;&nbsp;&nbsp;</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;PWD&nbsp;-&nbsp;Muestra&nbsp;el&nbsp;directorio&nbsp;actual&nbsp;de&nbsp;trabajo.</span><br />
<br />
<br />
<span class="style_9">IMPLEMENTATION</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;CAT</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">cat</span><span class="style_13">(</span><span class="style_9">var&nbsp;</span><span class="style_1">dir1</span><span class="style_13">,</span><span class="style_1">dir2</span><span class="style_13">:&nbsp;</span><span class="style_9">string</span><span class="style_13">;&nbsp;</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_9">var&nbsp;</span><span class="style_1">f1</span><span class="style_13">,</span><span class="style_1">f2</span><span class="style_13">:&nbsp;</span><span class="style_1">text</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">texto</span><span class="style_13">:&nbsp;</span><span class="style_9">string</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">err</span><span class="style_13">:&nbsp;</span><span class="style_1">boolean</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">err</span><span class="style_13">:=&nbsp;</span><span class="style_1">false</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_5">{$I-}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;Evita&nbsp;generar&nbsp;código&nbsp;de&nbsp;control&nbsp;de&nbsp;entrada/salida&nbsp;en&nbsp;el&nbsp;programa</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">assign</span><span class="style_13">(</span><span class="style_1">f1</span><span class="style_13">,</span><span class="style_1">dir1</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">reset</span><span class="style_13">(</span><span class="style_1">f1</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">IOResult&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">err&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">true&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;&nbsp;&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">while&nbsp;not&nbsp;</span><span class="style_1">eof</span><span class="style_13">(</span><span class="style_1">f1</span><span class="style_13">)&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">readln</span><span class="style_13">(</span><span class="style_1">f1</span><span class="style_13">,</span><span class="style_1">texto</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">texto</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">texto</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">close</span><span class="style_13">(</span><span class="style_1">f1</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">dir2&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_10">''&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">assign</span><span class="style_13">(</span><span class="style_1">f2</span><span class="style_13">,</span><span class="style_1">dir2</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">reset</span><span class="style_13">(</span><span class="style_1">f2</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">IOResult&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">err&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">true&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">while&nbsp;not&nbsp;</span><span class="style_1">eof</span><span class="style_13">(</span><span class="style_1">f2</span><span class="style_13">)&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">readln</span><span class="style_13">(</span><span class="style_1">f2</span><span class="style_13">,</span><span class="style_1">texto</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">texto</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">texto</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">close</span><span class="style_13">(</span><span class="style_1">f2</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">err&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">10</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_5">{$I+}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//&nbsp;Habilita&nbsp;la&nbsp;generación&nbsp;de&nbsp;código&nbsp;de&nbsp;entrada/salida</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;CD</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">El&nbsp;comando&nbsp;CD&nbsp;es&nbsp;ejecutado&nbsp;directamente</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">por&nbsp;el&nbsp;analizadorCD&nbsp;en&nbsp;la&nbsp;UNIT&nbsp;analizador</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_2">}</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;EXEC</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">exec&nbsp;</span><span class="style_13">(</span><span class="style_1">param1</span><span class="style_13">:&nbsp;</span><span class="style_9">String</span><span class="style_13">;&nbsp;</span><span class="style_1">param2</span><span class="style_13">:&nbsp;</span><span class="style_9">Array&nbsp;of&nbsp;</span><span class="style_1">AnsiString</span><span class="style_13">);</span><br />
<span class="style_9">var&nbsp;</span><span class="style_1">pid</span><span class="style_13">,</span><span class="style_1">op</span><span class="style_13">:&nbsp;</span><span class="style_1">longint</span><span class="style_13">;</span><br />
<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">op</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">pid</span><span class="style_13">:=&nbsp;-</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">fpFork&nbsp;</span><span class="style_9">of</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_13">-</span><span class="style_7">1</span><span class="style_13">:&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">3</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">0</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpExecLP</span><span class="style_13">(</span><span class="style_1">param1</span><span class="style_13">,</span><span class="style_1">param2</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpWaitPid</span><span class="style_13">(</span><span class="style_1">pid</span><span class="style_13">,</span><span class="style_1">op</span><span class="style_13">,</span><span class="style_1">op</span><span class="style_13">);&nbsp;</span><span class="style_4">//Espera&nbsp;por&nbsp;cualquier&nbsp;proceso&nbsp;hijo.</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;KILL</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">kill&nbsp;</span><span class="style_13">(</span><span class="style_1">signal</span><span class="style_13">,&nbsp;</span><span class="style_1">proc</span><span class="style_13">:&nbsp;</span><span class="style_1">longint</span><span class="style_13">);</span><br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpKill</span><span class="style_13">(</span><span class="style_1">proc</span><span class="style_13">,</span><span class="style_1">signal</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;LS</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">ls</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">Los&nbsp;archivos&nbsp;marcados&nbsp;como&nbsp;inaccesibles&nbsp;son&nbsp;aquellos&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">en&nbsp;los&nbsp;cuales&nbsp;fpStat&nbsp;devuelve&nbsp;un&nbsp;error.&nbsp;En&nbsp;dicho&nbsp;caso&nbsp;se&nbsp;puede&nbsp;saber</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;nombre&nbsp;del&nbsp;archivo,&nbsp;pero&nbsp;no&nbsp;datos&nbsp;referidos&nbsp;al&nbsp;tipo&nbsp;de&nbsp;archivo.</span><br />
<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio</span><span class="style_13">:&nbsp;</span><span class="style_1">pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">K</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada</span><span class="style_13">^.</span><span class="style_1">d_name</span><span class="style_13">[</span><span class="style_7">0</span><span class="style_13">]&nbsp;&lt;&gt;&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">burbujaDirent</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">,</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISLNK</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0B</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISDIR</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$09</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISREG</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;&lt;&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textAttr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$04</span><span class="style_13">;&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;&nbsp;</span><span class="style_4">//&nbsp;OpenDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<br />
<span class="style_4">//comando&nbsp;LS&nbsp;-a</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsA</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">Los&nbsp;archivos&nbsp;marcados&nbsp;como&nbsp;inaccesibles&nbsp;son&nbsp;aquellos&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">en&nbsp;los&nbsp;cuales&nbsp;fpStat&nbsp;devuelve&nbsp;un&nbsp;error.&nbsp;En&nbsp;dicho&nbsp;caso&nbsp;se&nbsp;puede&nbsp;saber</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;nombre&nbsp;del&nbsp;archivo,&nbsp;pero&nbsp;no&nbsp;datos&nbsp;referidos&nbsp;al&nbsp;tipo&nbsp;de&nbsp;archivo.</span><br />
<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio</span><span class="style_13">:&nbsp;</span><span class="style_1">pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">K</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">burbujaDirent</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">,</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISLNK</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0B</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISDIR</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$09</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISREG</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;=&nbsp;</span><span class="style_7">1</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">)[</span><span class="style_7">1</span><span class="style_13">]&nbsp;=&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;=&nbsp;</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textAttr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$04</span><span class="style_13">;&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;&nbsp;</span><span class="style_4">//&nbsp;OpenDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//comando&nbsp;LS&nbsp;-f</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsF</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">Los&nbsp;archivos&nbsp;marcados&nbsp;como&nbsp;inaccesibles&nbsp;son&nbsp;aquellos&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">en&nbsp;los&nbsp;cuales&nbsp;fpStat&nbsp;devuelve&nbsp;un&nbsp;error.&nbsp;En&nbsp;dicho&nbsp;caso&nbsp;se&nbsp;puede&nbsp;saber</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;nombre&nbsp;del&nbsp;archivo,&nbsp;pero&nbsp;no&nbsp;datos&nbsp;referidos&nbsp;al&nbsp;tipo&nbsp;de&nbsp;archivo.</span><br />
<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio</span><span class="style_13">:&nbsp;</span><span class="style_1">pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">K</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada</span><span class="style_13">^.</span><span class="style_1">d_name</span><span class="style_13">[</span><span class="style_7">0</span><span class="style_13">]&nbsp;&lt;&gt;&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textAttr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textAttr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$04</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;&nbsp;</span><span class="style_4">//&nbsp;OpenDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<br />
<span class="style_4">//comando&nbsp;LS&nbsp;-l</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsL</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">En&nbsp;caso&nbsp;de&nbsp;falla&nbsp;obteniendo&nbsp;los&nbsp;datos&nbsp;de&nbsp;un&nbsp;archivo&nbsp;se&nbsp;mostrará&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;mensaje&nbsp;"No&nbsp;se&nbsp;pudo&nbsp;mostrar.",&nbsp;que&nbsp;representa&nbsp;una&nbsp;falla&nbsp;en&nbsp;fpStat.</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">Pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_9">Begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//número&nbsp;de&nbsp;archivos&nbsp;listados</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada</span><span class="style_13">^.</span><span class="style_1">d_name</span><span class="style_13">[</span><span class="style_7">0</span><span class="style_13">]&nbsp;&lt;&gt;&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">burbujaDirent</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">,&nbsp;</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">+&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">R_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">W_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">X_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">35</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISLNK</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0B</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISDIR</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$09</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISREG</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;&lt;&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo</span><span class="style_13">=</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados:&nbsp;'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,&nbsp;</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//&nbsp;Procedure&nbsp;LS&nbsp;-l&nbsp;-a</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsLA</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">En&nbsp;caso&nbsp;de&nbsp;falla&nbsp;obteniendo&nbsp;los&nbsp;datos&nbsp;de&nbsp;un&nbsp;archivo&nbsp;se&nbsp;mostrará&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;mensaje&nbsp;"No&nbsp;se&nbsp;pudo&nbsp;mostrar.",&nbsp;que&nbsp;representa&nbsp;una&nbsp;falla&nbsp;en&nbsp;fpStat.</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">Pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_9">Begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//número&nbsp;de&nbsp;archivos&nbsp;listados</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">burbujaDirent</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">,&nbsp;</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">+&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">R_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">W_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">X_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">35</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISLNK</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0B</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISDIR</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$09</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpS_ISREG</span><span class="style_13">(</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_mode</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;&lt;=&nbsp;</span><span class="style_7">1</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">)[</span><span class="style_7">1</span><span class="style_13">]&nbsp;=&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">puntos</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;&lt;&nbsp;</span><span class="style_7">1</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">strPas</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">)[</span><span class="style_7">1</span><span class="style_13">]&nbsp;&lt;&gt;&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$0A</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo</span><span class="style_13">=</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados:&nbsp;'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,&nbsp;</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//&nbsp;Procedure&nbsp;LS&nbsp;-l&nbsp;-f</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsLF</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">En&nbsp;caso&nbsp;de&nbsp;falla&nbsp;obteniendo&nbsp;los&nbsp;datos&nbsp;de&nbsp;un&nbsp;archivo&nbsp;se&nbsp;mostrará&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;mensaje&nbsp;"No&nbsp;se&nbsp;pudo&nbsp;mostrar.",&nbsp;que&nbsp;representa&nbsp;una&nbsp;falla&nbsp;en&nbsp;fpStat.</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">Pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_9">Begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//número&nbsp;de&nbsp;archivos&nbsp;listados</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">and&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada</span><span class="style_13">^.</span><span class="style_1">d_name</span><span class="style_13">[</span><span class="style_7">0</span><span class="style_13">]&nbsp;&lt;&gt;&nbsp;</span><span class="style_10">'.'</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">+&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">R_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">W_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">X_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">35</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo</span><span class="style_13">=</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados:&nbsp;'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,&nbsp;</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsAF</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">Los&nbsp;archivos&nbsp;marcados&nbsp;como&nbsp;inaccesibles&nbsp;son&nbsp;aquellos&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">en&nbsp;los&nbsp;cuales&nbsp;fpStat&nbsp;devuelve&nbsp;un&nbsp;error.&nbsp;En&nbsp;dicho&nbsp;caso&nbsp;se&nbsp;puede&nbsp;saber</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;nombre&nbsp;del&nbsp;archivo,&nbsp;pero&nbsp;no&nbsp;datos&nbsp;referidos&nbsp;al&nbsp;tipo&nbsp;de&nbsp;archivo.</span><br />
<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio</span><span class="style_13">:&nbsp;</span><span class="style_1">pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">K</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
<br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio&nbsp;</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">25</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textAttr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$04</span><span class="style_13">;&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">case&nbsp;</span><span class="style_1">K&nbsp;</span><span class="style_9">of&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">1</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">2</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">27</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">j&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">)</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_7">3</span><span class="style_13">:&nbsp;&nbsp;</span><span class="style_9">begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">53</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Inaccesible:&nbsp;'</span><span class="style_13">,</span><span class="style_1">copy</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">,</span><span class="style_7">1</span><span class="style_13">,</span><span class="style_7">12</span><span class="style_13">):</span><span class="style_7">20</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//case</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">k&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">3&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">k</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">K</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;else&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End</span><span class="style_13">;&nbsp;</span><span class="style_4">//&nbsp;for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;&nbsp;</span><span class="style_4">//&nbsp;OpenDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//&nbsp;Procedure&nbsp;LS&nbsp;-a&nbsp;-f&nbsp;-l</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">lsAFL</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_2">{</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">En&nbsp;caso&nbsp;de&nbsp;falla&nbsp;obteniendo&nbsp;los&nbsp;datos&nbsp;de&nbsp;un&nbsp;archivo&nbsp;se&nbsp;mostrará&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_2">el&nbsp;mensaje&nbsp;"No&nbsp;se&nbsp;pudo&nbsp;mostrar.",&nbsp;que&nbsp;representa&nbsp;una&nbsp;falla&nbsp;en&nbsp;fpStat.</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_2">}</span><br />
<br />
<span class="style_9">var&nbsp;</span><span class="style_1">directorio&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">Pdir</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">PDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">info&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">stat</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_1">vDirent</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">,</span><span class="style_1">j&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_13">:&nbsp;</span><span class="style_9">integer</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<br />
<span class="style_9">Begin&nbsp;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">indice</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_7">0</span><span class="style_13">;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//número&nbsp;de&nbsp;archivos&nbsp;listados</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">directorio</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpOpenDir</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">directorio&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil&nbsp;then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">repeat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">entrada</span><span class="style_13">:=&nbsp;</span><span class="style_1">fpReadDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">entrada&nbsp;</span><span class="style_13">&lt;&gt;&nbsp;</span><span class="style_9">nil</span><span class="style_13">)&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">inc</span><span class="style_13">(</span><span class="style_1">indice</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">indice</span><span class="style_13">]:=&nbsp;</span><span class="style_1">entrada</span><span class="style_13">^;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="style_4">//if&nbsp;readDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">until&nbsp;</span><span class="style_1">entrada&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_9">nil</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">for&nbsp;</span><span class="style_1">J</span><span class="style_13">:=&nbsp;</span><span class="style_7">1&nbsp;</span><span class="style_9">to&nbsp;</span><span class="style_1">indice&nbsp;</span><span class="style_9">do</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">begin&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">fpStat</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">info</span><span class="style_13">)=</span><span class="style_7">0&nbsp;</span><span class="style_9">then</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">Begin&nbsp;</span><span class="style_4">//fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">contArchivos</span><span class="style_13">:=&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">+&nbsp;</span><span class="style_7">1</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'Permisos:&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">R_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'r&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">W_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'w&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_13">(</span><span class="style_1">fpAccess&nbsp;</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">),</span><span class="style_1">X_OK</span><span class="style_13">)=</span><span class="style_7">0</span><span class="style_13">)&nbsp;</span><span class="style_9">then&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'x&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'-&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">write</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'&nbsp;'</span><span class="style_13">,</span><span class="style_1">info</span><span class="style_13">.</span><span class="style_1">st_size</span><span class="style_13">,</span><span class="style_10">'&nbsp;bytes.&nbsp;'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">gotoxy</span><span class="style_13">(</span><span class="style_7">35</span><span class="style_13">,</span><span class="style_1">wherey</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">))&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">pchar</span><span class="style_13">(</span><span class="style_1">vector</span><span class="style_13">[</span><span class="style_1">J</span><span class="style_13">].</span><span class="style_1">d_name</span><span class="style_13">));</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">End&nbsp;</span><span class="style_4">//&nbsp;fpStat</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;se&nbsp;pudo&nbsp;mostrar.'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end</span><span class="style_13">;&nbsp;</span><span class="style_4">//for</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">textattr</span><span class="style_13">:=&nbsp;</span><span class="style_8">$07</span><span class="style_13">;</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-&nbsp;-'</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">contArchivos&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_10">'No&nbsp;hay&nbsp;listado.'</span><span class="style_13">)&nbsp;</span><span class="style_9">else</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados:&nbsp;'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,&nbsp;</span><span class="style_10">'Nro.&nbsp;de&nbsp;archivos&nbsp;listados'</span><span class="style_13">,</span><span class="style_1">contArchivos</span><span class="style_13">);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_1">fpCloseDir</span><span class="style_13">(</span><span class="style_1">directorio</span><span class="style_13">^);</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">end&nbsp;</span><span class="style_4">//openDir</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">else&nbsp;</span><span class="style_1">error</span><span class="style_13">(</span><span class="style_7">4</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_4">//Comando&nbsp;PWD</span><br />
<span class="style_9">procedure&nbsp;</span><span class="style_1">pwd</span><span class="style_13">(</span><span class="style_1">tipo</span><span class="style_13">:&nbsp;</span><span class="style_9">byte</span><span class="style_13">);</span><br />
<span class="style_9">Begin</span><br />
&nbsp;&nbsp;&nbsp;&nbsp;<span class="style_9">if&nbsp;</span><span class="style_1">tipo&nbsp;</span><span class="style_13">=&nbsp;</span><span class="style_7">0&nbsp;</span><span class="style_9">then&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">dirActual</span><span class="style_13">)&nbsp;</span><span class="style_9">else&nbsp;</span><span class="style_1">writeln</span><span class="style_13">(</span><span class="style_1">stdOutPut</span><span class="style_13">,</span><span class="style_1">dirActual</span><span class="style_13">);</span><br />
<span class="style_9">End</span><span class="style_13">;</span><br />
<br />
<br />
<span class="style_9">END</span><span class="style_13">.</span><br />

</p>
</body>
</html>

